//---------------------------------------------------------------------------

#ifndef h_transferthreadH
#define h_transferthreadH
//---------------------------------------------------------------------------
class HTransferThread : public HThread
{
public :

   __fastcall HTransferThread(bool CreateSuspended);
   virtual __fastcall ~HTransferThread(void);
   virtual void __fastcall Execute(void);
   void __fastcall SetOverwrite(bool Overwrite);
   bool __fastcall WaitForOverwriteEvent(void);

   __property string FullFileName = { write = FFullFileName };
   __property string FileName = { write = FFileName };
   __property string Id = { write = FId };
   __property string Password = { write = FPassword };
   __property string IpAddr = { write = FIpAddr };
   __property int Port = { write = FPort };
   __property string Protocol = { write = FProtocol };
   __property string ResultMsg = { read = FResultMsg };
   __property string Author = { read = FAuthor };
   __property string Description = { read = FDescription };

private :

   string __fastcall GetProgressMsg(void);
   void __fastcall SetProgressMsg(const string &Msg);
   bool __fastcall GetText(vector<string> &Text);

   string FFullFileName;
   string FFileName;
   string FId;
   string FPassword;
   string FIpAddr;
   int FPort;
   string FProtocol;
   string FResultMsg;
   string FAuthor;
   string FDescription;
   bool FOverwrite;
   TSimpleEvent *FOverwriteEvent;
};

#endif
